home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Collection of Tools & Utilities
/
Collection of Tools and Utilities.iso
/
batchut
/
fkeymenu.zip
/
FKEYMENU.DOC
< prev
next >
Wrap
Text File
|
1991-11-06
|
4KB
|
78 lines
╓───────────────────────────────╖
║ ╒╤════════════════╤╕ ║
║ ││ FKEYMENU.BAT ││ ║
║ ╘╧════════════════╧╛ ║
╙───────────────────────────────╜
FKEYMENU.BAT allows you to use the Function keys (F1 to 10) to
select different commands or programs. FKEYMENU.BAT uses a small
.COM program --GETFKEY.COM-- to restrict input to just the 10
Function keys on the keyboard. This makes a fairly "bulletproof"
batch file to perform sensitive actions such as formatting
diskettes.
FKEYMENU.BAT is also an excellent menuing program for a laptop
with a small or no hard drive. Several of my computer
friends have adopted this program because it is both simple and
easily configured.
You can modify the menu MENU.DAT, with a word processor capable
of ASCII editing to reflect the programs or commands that you
wish to access from this batch file. Before you do, run
DEMO.BAT to give you an idea of a real life example; sometimes
doing is better than reading.
There are four (3) files that are necessary to run this batch file
program, they are:
1. FKEYMENU.BAT <-- the program
2. GETFKEY.COM <-- waits for a key press
3. MENU.DAT <-- the menu displayed to the screen
This file, FKEYMENU.DOC should probably be saved as well.
For variety, I used bright white on red as the menu colors in
MENU.DAT. Other colors can be used by changing the ANSI string in
the first line. These color codes are found in almost any MS-DOS
text that discusses ANSI codes, but if you REALLY want bright
white on blue all you have to do is substitute the number 41 with
44, do it carefully, do not erase any code or add any spaces...
REMEMBER, use an ASCII editor with MENU.DAT so that no strange
formatting code creeps in. If you are not sure about your
editing, just use the MS-DOS TYPE command to see this file after
you have edited it. The command for that is:
TYPE MENU.DAT {Enter}.
When you have finished editing MENU.DAT, make sure there are only
24 lines in MENU.DAT. If you add additional lines at the bottom,
everytime FKEYMENU.BAT displays it, it will scroll upwards and
you will lose the top of the menu.
Now go to FKEYMENU.BAT. After each "label" (the words with a
colon in front of them, i.e. :F1...), replace the commands with
your commands. Run DEMO.BAT to see how this works. Do NOT erase
any "goto" commands as these commands loop the batch file back to
the beginning, redisplays the menu, and keeps you in the program.
The F10 key is set to quit the program. You will note that the
Escape key <Esc> does not abort this batch file. No other SINGLE
key except the designated Function key should cause a selection.
Let me know if you find a bug. This batch file is simple yet
almost "bullet-proof."
Other files in this file set are:
1. DEMO.DAT -- sample menu for DEMO.BAT
2. DEMO.BAT -- demonstration batch file
3. TEST.BAT -- run and then read to learn a little
about ANSI commands.
4. OFFICE.BAT -- demo of a menu that we use in the
office
5. BMENU.BAS -- the menu for OFFICE.BAT
6. GETBSAVE.EXE -- a QuickBASIC program that will load
BLOAD graphic files such as BMENU.BAS
John De Palma Wed 11-06-1991 02:38:58.